package com.mysoft.gfyx.clue.controller;

import com.mysoft.framework.mvc.api.Controller;
import com.mysoft.framework.rpc.annotation.PubAction;
import com.mysoft.framework.rpc.annotation.PubService;
import com.mysoft.framework.rpc.contants.RequestPrefix;
import com.mysoft.gfyx.clue.controller.dto.DeleteByIdRequestDto;
import com.mysoft.gfyx.clue.controller.dto.PubAddCustomersRequestDto;
import com.mysoft.gfyx.clue.controller.dto.PubGetCustomerRequestDto;
import com.mysoft.gfyx.clue.remoteservice.RemoteDeveloperService;
import com.mysoft.gfyx.clue.remoteservice.dto.GetPurchaseContactsRequestDto;
import com.mysoft.gfyx.clue.service.CustomerPoolService;
import com.mysoft.gfyx.clue.service.CustomerService;
import com.mysoft.gfyx.clue.service.dto.CustomerDto;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMethod;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;
import java.util.Set;

@PubService(value = "/contacterPub", prefix = RequestPrefix.PUB)
public class ContacterPubController extends Controller {

    @Autowired
    private RemoteDeveloperService remoteDeveloperService;

    @PubAction(value = "/getPurchaseContacts", method = RequestMethod.POST)
    public List<Map<String, Object>> getPurchaseContacts(@RequestBody GetPurchaseContactsRequestDto dto) {
        return remoteDeveloperService.getPurchaseContacts(dto);
    }


}
